<!DOCTYPE>
<html>
<head>
  <title>Core Reporting API v3 Reference Example</title>
  <link rel="stylesheet" type="text/css"
      href="//fonts.googleapis.com/css?family=Cantarell|Inconsolata">
  <link rel="stylesheet" type="text/css"
      href="pretty.css">
</head>
<body>
<h1>Core Reporting API v3 Reference Example</h1>
<p>This page demonstrates how to use the
   <a href="https://code.google.com/p/google-api-javascript-client/">
      Google API Javascript Client Library</a> to access all the important
      information from the
   <a href="http://code.google.com/apis/analytics/docs/gdata/v3/gdataGettingStarted.html">
      Core Reporting API</a>.</p>

<p>To learn how this works, read the detailed comments in the
   <a href="core_reporting_api_v3_reference.js">JavaScript source code</a>.</p>

<p>To run the demo:</p>
<ol>
  <li>Click the authorize button to grant access to your Google Analytics data.</li>
  <li>Fill in the required Table Id parameter.</li>
  <li>Click the run demo button to start the demo.</li>
</ol>

<hr>
<button id="authorize-button" style="visibility: hidden">Authorize</button>

<ul id="ga-table">
  <li><p class="c1">Table Id:</p>
      <input id="table-id" class="c2"></input>
      <p class="note">Format is ga:xxx where xxx is your profile ID.</p></li>
  <li><p class="c1">Start Date:</p>
      <input id="start-date" class="c2"></input></li>
  <li><p class="c1">End Date:</p>
      <input id="end-date" class="c2"></input></li>
</ul>
<button id="run-demo-button" style="visibility: hidden">Run Demo</button>

<hr>
<div id="output">Loading, one sec....</div>

<script src="auth_util.js"></script>
<script src="core_reporting_api_v3_reference.js"></script>
<script src="https://apis.google.com/js/client.js?onload=handleClientLoad"></script>

</body>
</html>